{% load i18n %}
<h2>{{ action_title|default:phrases.base.delete_confirm_heading }}</h2>
<hr>
<p><strong>{{ action_object_name }}</strong></p>
<p>{{ action_text|default:phrases.base.delete_warning }}</p>
<form method="post">
    {% csrf_token %}
    <div class="submit-group">
        <a href="{{ action_back_url|default:".." }}" class="btn btn-lg btn-{{ action_back_color|default:"outline-info" }}">
            {% if action_back_icon %}<i class="fa fa-{{ action_back_icon }}"></i>{% endif %}
            {{ action_back_label|default:phrases.base.back_button }}
        </a>
        <div>
            {% for action in additional_actions %}
                {% if action.href %}
                    <a href="{{ action.href }}" class="btn btn-lg btn-{{ action.color }}">
                        <i class="fa fa-{{ action.icon }}"></i>
                        {{ action.label }}
                    </a>
                {% else %}
                    <button type="submit" class="btn btn-lg btn-{{ action.color }}" name="{{ action.name }}" value="{{ action.value }}">
                        {% if action.icon %}<i class="fa fa-{{ action.icon }}"></i>{% endif %}
                        {{ action.label }}
                    </button>
                {% endif %}
            {% endfor %}
            <button type="submit" class="btn btn-lg btn-{{ action_confirm_color|default:"danger" }}" {% if action_confirm_name %}name="{{ action_confirm_name }}"{% endif %} {% if action_confirm_value %}value="{{ action_confirm_value }}"{% endif %}>
                {% if action_confirm_icon != "" %}<i class="fa fa-{{ action_confirm_icon|default:"trash" }}"></i>{% endif %}
                {{ action_confirm_label|default:phrases.base.delete_button }}
            </button>
        </div>
    </div>
</form>
